package com.qianda.qdminiapp.dao.device;

import com.qianda.qdminiapp.domain.model.device.Device;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author cw
 * @since 2019-08-07
 */
public interface DeviceDao extends BaseMapper<Device> {

    /*
     * 毛巾余量减一
     * @Description
     * @Author cw
     * @Date 10:59 2019/8/7
     * @Param []
     * @return void
     **/
    void deviceTowelCountMinusOne(Integer deviceId);

    /*
     * 查询购买数量
     * @Description
     * @Author cw
     * @Date 13:15 2019/8/7
     * @Param [orderDeviceId, userId]
     * @return java.lang.Integer
     **/
    Integer  checkUserIsBought(String orderDeviceId,Integer userId);


}
